home *** CD-ROM | disk | FTP | other *** search
/ The Atari Compendium / The Atari Compendium (Toad Computers) (1994).iso / files / prgtools / mint / network / lattice / portlib.lzh / PORTLIB / WRITEV.C < prev    next >
Encoding:
C/C++ Source or Header  |  1994-05-20  |  331 b   |  22 lines

  1. #include <stddef.h>
  2. #include <sys/socket.h>
  3. #include <sys/uio.h>
  4.  
  5. int
  6. writev (s, iov, niov)
  7.     int s;
  8.     struct iovec *iov;
  9.     size_t niov;
  10. {
  11.     struct msghdr m;
  12.  
  13.     m.msg_name = 0;
  14.     m.msg_namelen = 0;
  15.     m.msg_iov = iov;
  16.     m.msg_iovlen = niov;
  17.     m.msg_accrights = 0;
  18.     m.msg_accrightslen = 0;
  19.  
  20.     return sendmsg (s, &m, 0);
  21. }
  22.